import VueRouter from 'vue-router'
import home from './components/tabbar/HomeContainer.vue'
import member from './components/tabbar/MemberContainer.vue'
import shopcar from './components/tabbar/ShopcarContainer.vue'
import search from './components/tabbar/SearchContainer.vue'
import newslist from './components/news/NewsList.vue'
import newsinfo from './components/news/NewsInfo.vue'
import photoslist from './components/photos/PhotosList.vue'
import photoinfo from './components/photos/PhotoInfo.vue'
import goodslist from './components/goods/GoodsList.vue'
import goodsinfo from './components/goods/GoodsInfo.vue'
import goodsdesc from './components/goods/GoodsDesc.vue'
import goodscomment from './components/goods/GoodsComment.vue'


var router=new VueRouter({
    routes:[
        { path:'/',redirect:'/home' },
        { path:'/home',component:home },
        { path:'/member',component:member },
        { path:'/shopcar',component:shopcar },
        { path:'/search',component:search },
        {path:'/home/newlist',component:newslist},
        {path:'/home/newsinfo/:id',component:newsinfo},
        {path:'/home/photoslist',component:photoslist},
        {path:'/home/photoinfo/:id',component:photoinfo},
        {path:'/home/goodslist',component:goodslist},
        {path:'/home/goodsinfo/:id',component:goodsinfo},
        {path:'/home/goodsdesc/:id',component:goodsdesc,name:'goodsdesc'},
        {path:'/home/goodscomment/:id',component:goodscomment,name:'goodscomment'}
    ],
    linkActiveClass:'mui-active' //覆盖默认的路由高两类( router-link-active )
})

export default router